<?php
function D($vars=null)
{
	if(is_null($vars))
	{
		echo(' !Debug! ');
		return;
	}
	if(is_array($vars))
	{
		print("<table><tr><td>Var</td><td>Value</td></tr>");
		foreach ($vars as $var)
		{
			print("<tr><td>$var</td><td>".$GLOBALS[$var]."</td></tr>");
		}
		print("</table>");
	}
	elseif (is_object($vars))
	{
		print("<table><tr><td>Var</td><td>Value</td></tr>");
		foreach ($vars as $k=>$v)
		{
			print("<tr><td>$k</td><td>$v</td></tr>");	
		}
		print("</table>");
	}
	else 
	{
		print("<table><tr><td>Var</td><td>Value</td></tr>");
		print("<tr><td>$vars</td><td>".$GLOBALS[$vars]."</td></tr>");
		print("</table>");
	}
}
?>